<!DOCTYPE html>
<html lang="zh-cn">
    <head>
        <meta charset="UTF-8"/>
        <meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0" />
        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
        <title>isotope基本使用</title>
        <style>
            .grid-item { width: 25%; }
            .grid-item--width2 { width: 50%; }
        </style>
    </head>
    <body>
        <div class="grid">
          <div class="grid-item">...</div>
          <div class="grid-item grid-item--width2">...</div>
          <div class="grid-item">...</div>
        </div>
        <script src="http://cdn.bootcss.com/jquery/1.10.2/jquery.min.js"></script>
        <script src="js/isotope.pkgd.min.js"></script>
        <script>
            $('.grid').isotope({
              // options
              itemSelector: '.grid-item',
              layoutMode: 'fitRows'
            });
        </script>
    </body>
</html>